package com.jprocms.module.cms.controller.admin.model.vo;


import com.mzt.logapi.starter.annotation.DiffLogField;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import javax.validation.constraints.NotNull;

/**
 * 模型 Base VO，提供给添加、修改、详细的子 VO 使用
 * 如果子 VO 存在差异的字段，请不要添加到这里，影响 Swagger 文档生成
 */
@Data
public class ModelBaseVO {

    @Schema(description = "名称", required = true)
    @NotNull(message = "名称不能为空")
    @DiffLogField(name = "名称")
    private String name;

    @Schema(description = "模板前缀", required = true)
    @NotNull(message = "模板前缀不能为空")
    @DiffLogField(name = "模板前缀")
    private String tplPrefix;

    @Schema(description = "是否全局(1全局  0站点模型)", required = true)
    @NotNull(message = "是否全局(1全局  0站点模型)不能为空")
    @DiffLogField(name = "是否全局")
    private Integer isGlobal;

    @Schema(description = "站点ID")
    private Long siteId;

    @Schema(description = "开启状态", required = true)
    @NotNull(message = "开启状态不能为空")
    @DiffLogField(name = "开启状态")
    private Integer status;

    @Schema(description = "模型类型（1-栏目模型  2-内容模型）", required = true)
    @NotNull(message = "模型类型（1-栏目模型  2-内容模型）不能为空")
    private Integer modelType;

    @Schema(description = "排序值", required = true)
    @NotNull(message = "排序值不能为空")
    @DiffLogField(name = "排序值")
    private Integer sort;

    @Schema(description = "主面板区域字段json")
    @DiffLogField(name = "主面板区域字段")
    private String mainFields;

    @Schema(description = "自定义字段json")
    @DiffLogField(name = "自定义字段")
    private String customs;

    @Schema(description = "面板右侧自定义字段json")
    @DiffLogField(name = "面板右侧自定义字段")
    private String rightFields;

}
